#ifndef GL_RENDER_H
#define GL_RENDER_H

#include "BaseSample.h"

class GLRender
{
    GLRender();

    ~GLRender();

public:
    int m_ParentViewWidth;
    int m_ParentViewHeight;
    float m_ratio;

    void SetImageData(int format, int width, int height, uint8_t *pData);

    void SetParamsInt(int paramType, int value);

    void OnSurfaceCreated();

    void OnSurfaceChanged(int width, int height);

    void OnDrawFrame();

    static GLRender* GetInstance();
    static void DestroyInstance();

private:
    static GLRender *m_pContext;
    BaseSample *m_Sample;

};

#endif